Skip to content

Materialize responsive layout companion blocks - #1301

Merged
chubes4 merged 12 commits into
mainfrom
fix/1143-responsive-layout-renderer
Aug 25, 2026
Merged

Materialize responsive layout companion blocks#1301
chubes4 merged 12 commits into
mainfrom
fix/1143-responsive-layout-renderer

Conversation

@chubes4

@chubes4 chubes4 commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • consume the producer-owned blocks-engine/wordpress-companion-plugin/v1 contract
  • map generic responsive media/layout capabilities through a fail-closed, filterable WordPress renderer registry
  • preserve bounded semantic HTML, responsive media, safe SVG presentation, and required runtime assets
  • restore producer metadata exactly during materialization rollback

Closes #1255

Producer: Automattic/blocks-engine#1191

Verification

  • php tests/smoke-companion-plugin.php (338 assertions)
  • php tests/smoke-post-meta-rollback.php

AI assistance

OpenCode with OpenAI gpt-5.6-sol traced Puffin materialization failures and the producer/consumer ownership leak, migrated SSI to producer-owned contracts, added registry validation, and reran companion-renderer and rollback coverage. Chris Huber directed the architecture and remains responsible for the change.

@aagam-shah

Copy link
Copy Markdown

Tested this branch (5f812b0) paired with Automattic/blocks-engine#1191 (ae9716ef) on a real 28-page Wix store artifact (102 MB) through Studio's create --from flow (Automattic/studio#3952).

Result: all 28 pages compile, then materialization is rejected by two policy gates before anything renders.

  1. SSI quality gate (fail_on_quality: true, which Studio sets): 2 unsupported fallbacks, both the site's contact form (desktop and mobile variants) — interactive_form / form:form_requires_runtime:server_or_client_form_handler, island type provider_materializable_form, repair class materialize_form_provider. The gate runs at plan_artifact, before the dependency lifecycle that could materialize the form, so materialize_dependencies: true and seed_entities: true do not help.
  2. Blocks Engine editability policy (enforcement: required): max_nesting_depth 26, maximum 20, on 10 pages (36 failures). Wix wraps <main> in 21+ divs.

The plan-only route (wp static-site-importer materialize-wordpress-site-plan on the composed wordpress-site-plan/v2) is rejected with the same editability failure, plus 278 author_layout_topology_changed and 110 html_semantic_parity_navigation_menu_missing diagnostics. The composed plan holds 2 custom/responsive-layout, 54 custom/responsive-media, 1,614 custom/layout-shell, and 58 core/html blocks.

For comparison, Blocks Engine trunk 4c543747 + SSI main 6184b18 on the same artifact: the gates pass (the form sits inside the swallowed <main>), 32 pages materialize, and the frontend renders header and footer only (#1255 / blocks-engine#1143).

Size and time, this branch vs trunk (same artifact, same machine; both runs overlapped, so timings are inflated): shared plan 231 MB vs 39 MB; prepare_pages 354 s vs 174 s; compile_pages 728 s vs 427 s; compose 147 s both; composed result 842 MB vs 835 MB.

So on a Wix site this branch surfaces the real content, but the two gates stop it before a page renders. Happy to share the artifact and run directory privately.

AI assistance: Claude Code (Claude Fable 5) ran the comparison and drafted this comment. Aagam Shah directed the work and is responsible for it.

@chubes4
chubes4 merged commit 2edd49e into main Aug 25, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Materialize the typed responsive-layout companion renderer

2 participants